var app = getApp();

Page({

  /**
   * 页面的初始数据
   */
  data: {

  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    var that = this;
  },

  PickerChange: function (e) {
    var that = this;
    console.log(that.data.obj[e.detail.value])
    console.log(e)
    that.setData({
      val: e.detail.value
    })
  },
  formSubmit: function (e) {
    var that = this;
    var page = this;
    var card = new Object();
    console.log('picker发送选择改变1，携带值为', that.data.obj[that.data.val])

  },

  /**
   * 视图切换
   */
  refreshOpen: function (e) {
    if (e.currentTarget.dataset.index == 1) {
      wx.navigateTo({
        url: "../barRefresh/barRefresh",
      })
    }
    if (e.currentTarget.dataset.index == 2) {
      wx.navigateTo({
        url: "../sildeTest/sildeTest",
      })
    }
    if (e.currentTarget.dataset.index == 3) {
      wx.navigateTo({
        url: "../xqpoint/xqpoint",
      })
    }
  },

  APIOpen: function () {
    wx.navigateTo({
      url: "../testAPI/testAPI",
    })
  },

  makePhoneCall: function () {
    wx.makePhoneCall({
      phoneNumber: '18286044741',
    })
  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function (options) {
    
  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})